import java.awt.*;

public class Camera
{
    private Point2D pos;
    private Dimension dim;

    public Camera (double x, double y, int l, int h)
    {
	pos = new Point2D(x,y);
	dim = new Dimension(l,h);

    }
    
    public Camera (Point2D p,Dimension d)
    {
	pos = p.dupliquer();
	dim = new Dimension(d);//passage par valeur
    }
    
    public double getX()
    {
	return pos.getX();
    }

    public double getY()
    {
	return pos.getY();
    }

    public void setPos(Point2D p)
    {
	pos.setXY(p.getX(),p.getY());
    }
    public void setX(double x)
    {
	pos.setX(x);
    }

    public void setY(double y)
    {
	pos.setY(y);
    }


    public double getWidth()
    {
	return dim.getWidth();
    }

    public double getHeight()
    {
	return dim.getHeight();
    }//pas de setHeight pour l'instant, possible si on decide de donner la possibilite de redimensionner la fenetre...

    public void move(double vx, double vy)
    {
	pos.translater(vx,vy);
    }
}